package verticle;

import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;

/**
 * FileLocation
 *
 * @author liyixin
 * @date 2019/6/5
 */
public class FileLocation {

    private static final Path PATH1 = Paths.get("/fs-SP1-0/");

    private static final Path PATH2 = Paths.get("/fs-SP1-1/");

    private static final Path PATH3 = Paths.get("/fs-SP2-0/");

    private static final Path PATH4 = Paths.get("/fs-SP2-1/");

    public static String getPath() {
        if(Files.exists(PATH1)) {
            return PATH1.toString();
        } else if(Files.exists(PATH2)) {
            return PATH2.toString();
        } else if(Files.exists(PATH3)) {
            return PATH3.toString();
        } else {
            return PATH4.toString();
        }
    }
}
